home *** CD-ROM | disk | FTP | other *** search
/ HiJaak Graphics Suite 3.0 / HiJaak Graphics Suite V3.iso / inset / spots.pdp < prev    next >
Text File  |  1992-04-14  |  3KB  |  121 lines

  1. %GSSpots: Dot1, Default Dots
  2. /Dot1 { %def: The default screen on PS 38.0 and up
  3.     abs exch abs 2 copy add 1 gt { 1 sub dup mul exch
  4.     1 sub dup mul add 1 sub } {dup mul exch dup mul add
  5.     1 exch sub} ifelse
  6.      } bind def
  7. %GSEnd
  8.  
  9. %GSSpots: Dot2, Corner Out Dots
  10. /Dot2 { %def: do dot from corners into centre
  11.     abs exch abs 1 sub dup mul exch 1 sub dup mul add 1 sub
  12.     } bind def
  13. %GSEnd
  14.  
  15.  
  16. %GSSpots: Triangle, Triangles
  17. /Triangle {
  18.       2 exch sub exch abs 2 mul sub 3 div
  19.       } bind def
  20. %GSEnd
  21.  
  22. %GSSpots: Ellipse, Long Ellipse
  23. /Ellipse  { %def: longer ellipse
  24.       2 mul abs exch dup mul add 3 div 2 mul 1 exch sub
  25.       } bind def
  26. %GSEnd
  27.  
  28. %GSSpots: Ellipse2, Ellipse
  29. /Ellipse2 { %def: more rounder ellipse
  30.       1.4 mul abs exch dup mul add 3 div 2 mul 1 exch sub
  31.       } bind def
  32. %GSEnd
  33.  
  34. %GSSpots: Diamond, Diamonds
  35. /Diamond {
  36.      abs exch abs add 1 exch sub
  37.      } bind def
  38. %GSEnd
  39.  
  40. %GSSpots: Square, Squares
  41. /Square {
  42.     abs exch abs exch 2 copy lt { exch pop } { pop } ifelse
  43.     } bind def
  44. %GSEnd
  45.  
  46.  
  47. %GSSpots: Spiral5, 5 Spoked Propeller
  48. /Spiral5 {
  49.     /y exch def
  50.     /x exch def
  51.  
  52.     /theta y x .001 add atan cvi def
  53.  
  54.     theta 72 mod 72 sub abs 72 div
  55.     y y mul x x mul add 1 exch sub add 2 div
  56.     } bind def
  57. %GSEnd
  58.  
  59. %GSSpots: Spiral10, 10 Spoked Propeller
  60. /Spiral10 { %def: 10 spoked propeller - REALLY NEAT!!!
  61.     /y exch def
  62.     /x exch def
  63.  
  64.     /theta y x .001 add atan cvi def
  65.  
  66.     theta 36 mod 36 sub abs 60 div
  67.     y y mul x x mul add 1 exch sub add 2 div
  68.     } bind def
  69. %GSEnd
  70.  
  71. %GSSpots: Ducks, Cute Duck Shapes
  72. /Ducks { %def: actually a Spiral3 - not very useful, but cute!
  73.     /y exch def
  74.     /x exch def
  75.  
  76.     /theta y x .001 add atan cvi def
  77.  
  78.     theta 144 mod 144 sub abs 144 div
  79.     y y mul x x mul add 1 exch sub add 2 div
  80.     } bind def
  81. %GSEnd
  82.  
  83. %GSSpots: Line, Lines
  84. /Line { %def: TKK's definition of a Line
  85.     pop
  86.       } bind def
  87. %GSEnd
  88.  
  89. %GSSpots: TwoCirc1, White Rings
  90. /TwoCirc1 { %def:
  91.     dup mul exch dup mul add 0.65 exch sub abs 0.5 mul
  92.     } bind def
  93. %GSEnd
  94.  
  95. %GSSpots: TwoCirc2, Black Rings
  96. /TwoCirc2 { %def: slightly improved Corel OutCircWht
  97.     dup mul exch dup mul add 0.65 exch sub abs -0.5 mul
  98.      } bind def
  99. %GSEnd
  100.  
  101. %GSSpots: Waves1, In-Phase Waves
  102. /Waves1 { %
  103.     /e exch def
  104.     180 mul sin 2 div e dup dup dup mul mul sub mul e add 180 mul sin
  105.     } bind def
  106. %GSEnd
  107.  
  108. %GSSpots: Waves2, Out-Of-Phase Waves
  109. /Waves2 {
  110.     /e exch def
  111.     180 mul cos 2 div e dup dup dup mul mul sub mul e add 180 mul cos
  112.     } bind def
  113. %GSEnd
  114.  
  115.  
  116. %GSSpots: Grids, Grids
  117. /Grids { %
  118.     2 copy abs exch abs gt {exch} if pop 2 mul 1 exch sub 3.5 div
  119.     } bind def
  120. %GSEnd
  121.